class Bird(object):
    def eat(self, worm):
        print(f"小鸟在吃{worm.color}的虫子")


class Worm(object):
    def __init__(self, color):
        self.color = color


worm1 = Worm("黑色")

bird = Bird()
bird.eat(worm1)








class Person(object):
    def play(self,ball):
        print(f"人在玩{ball.name}")

class Ball(object):
    def __init__(self,name):
        self.name = name


ball1 = Ball("篮球")

p = Person()
p.play(ball1)







class Person(object):
    def eat(self,food):
        print(f"人在吃{food,name}")



class Food(object):
    def __init__(self,name):
        self.name = name


food1 = Food("面条")

p1 = Person
p1.eat(food1)















